package com.ht.demo.service.manager.system;

import com.ht.demo.common.appexception.AppException;
import com.ht.demo.common.page.PageBO;
import com.ht.demo.common.pojo.bo.system.SysDictDataBO;
import com.ht.demo.common.pojo.bo.system.SysDictTypeBO;
import com.ht.demo.common.pojo.bo.system.SysUserBO;
import com.ht.demo.common.pojo.qto.system.SysDictDataQTO;
import com.ht.demo.common.pojo.qto.system.SysDictTypeQTO;

import java.util.List;

/**
 * @Author hdengxian
 * @Date 2023/5/24 16:39
 */

public interface SysDictManager {
    boolean saveDictType(SysUserBO user, SysDictTypeBO dictTypeBO) throws AppException;

    boolean updateDictType(SysUserBO user, SysDictTypeBO dictTypeBO) throws AppException;

    boolean deleteDictType(Long sysDictTypeId) throws AppException;

    SysDictTypeBO findDictTypeById(Long sysDictTypeId) throws AppException;

    PageBO<SysDictTypeBO> findDictTypeForPage(SysDictTypeQTO qto) throws AppException;

//===============================================================================

    boolean saveDictData(SysUserBO user, SysDictDataBO dictDataBO) throws AppException;

    boolean updateDictData(SysUserBO user, SysDictDataBO dictDataBO) throws AppException;

    boolean deleteDictDataByType(String dictType) throws AppException;

    boolean deleteDictData(String sysDictDataId) throws AppException;

    SysDictDataBO findDictDataById(String sysDictDataId) throws AppException;

    List<SysDictDataBO> findDictDataListByType(String dictType) throws AppException;

    PageBO<SysDictDataBO> findDictDataForPage(SysDictDataQTO qto) throws AppException;
}
